#include <cstdio>
#include <algorithm>
#include <vector>
using namespace std;
vector<int> r;
int main(void){
    int n;
    while(~scanf("%d",&n)){
        r.clear();
        while(n){
            r.push_back(n%2);
            n/=2;
        }
        int l=r.size();
        for(int i=l-1;i>0;i--){
            printf("%d",r[i]);
        }
        printf("%d\n",r[0]);
    }
    return 0;
}
